using System.ComponentModel.DataAnnotations.Schema;
using System.Data.Entity.ModelConfiguration;

namespace ConsoleApplication2.Models.Mapping
{
    public class HL7_BufferMap : EntityTypeConfiguration<HL7_Buffer>
    {
        public HL7_BufferMap()
        {
            // Primary Key
            this.HasKey(t => t.id);

            // Properties
            this.Property(t => t.LastCasenb)
                .HasMaxLength(50);

            this.Property(t => t.App_UID)
                .HasMaxLength(50);

            this.Property(t => t.App_Date)
                .HasMaxLength(50);

            this.Property(t => t.App_Time)
                .HasMaxLength(50);

            this.Property(t => t.App_duration)
                .HasMaxLength(50);

            this.Property(t => t.App_Unit)
                .HasMaxLength(50);

            this.Property(t => t.App_Status)
                .HasMaxLength(50);

            this.Property(t => t.app_itemCode)
                .HasMaxLength(50);

            this.Property(t => t.App_Item)
                .HasMaxLength(50);

            this.Property(t => t.App_Action)
                .HasMaxLength(50);

            // Table & Column Mappings
            this.ToTable("HL7_Buffer");
            this.Property(t => t.id).HasColumnName("id");
            this.Property(t => t.LastCasenb).HasColumnName("LastCasenb");
            this.Property(t => t.App_UID).HasColumnName("App_UID");
            this.Property(t => t.App_Date).HasColumnName("App_Date");
            this.Property(t => t.App_Time).HasColumnName("App_Time");
            this.Property(t => t.App_duration).HasColumnName("App_duration");
            this.Property(t => t.App_Unit).HasColumnName("App_Unit");
            this.Property(t => t.App_Status).HasColumnName("App_Status");
            this.Property(t => t.app_itemCode).HasColumnName("app_itemCode");
            this.Property(t => t.App_Item).HasColumnName("App_Item");
            this.Property(t => t.App_Action).HasColumnName("App_Action");
        }
    }
}
